package com.mybatisplus.mp.pojo;

import lombok.Builder;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

import javax.validation.Valid;
import javax.validation.constraints.NotNull;
import java.util.List;

@Getter
@Setter
@Builder
@ToString
public class ValidPojo {
    @NotNull(message = "name不能为空"/*,groups = Group.class*/)
    private String name;
    @Valid  //可以校验list对象里的属性(只会校验不为null的数据，如果要检测null，需要外层加@notnull)
    //    @NotNull(message = "user不能为空")
    private List<UserListForValid> users;




}
